During execution of a program, an object can be created or destroyed in computer memory. The object can include members that have complex data structures. The members often need to be initialized during creation of the object, and to be cleaned up during destruction of the object. The initialization and clean-up may include, for example, operations of allocating or freeing memory. When the members of the object include complex data structures, the creation or destruction of the object can be expensive in terms of the number of operations to be performed and amount of memory to be allocated and de-allocated. To reduce the expense, object-recycling techniques can be used. When a procedure requests destruction of an object, the object can be placed into an object pool, rather than destroyed. When a procedure requests a new object, the object in the object pool, rather than a new object, can be returned to the procedure. A locking mechanism can be used to manage the object pool to avoid potential conflicts.